package com.shop.goods.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.shop.goods.mapper.ShopSortMapper;
import com.shop.goods.domain.ShopSort;
import com.shop.goods.service.IShopSortService;

/**
 * 商品分类Service业务层处理
 * 
 * @author ruoyi
 * @date 2022-03-23
 */
@Service
public class ShopSortServiceImpl implements IShopSortService 
{
    @Autowired
    private ShopSortMapper shopSortMapper;

    /**
     * 查询商品分类
     * 
     * @param sortId 商品分类主键
     * @return 商品分类
     */
    @Override
    public ShopSort selectShopSortBySortId(Long sortId)
    {
        return shopSortMapper.selectShopSortBySortId(sortId);
    }

    /**
     * 查询商品分类列表
     * 
     * @param shopSort 商品分类
     * @return 商品分类
     */
    @Override
    public List<ShopSort> selectShopSortList(ShopSort shopSort)
    {
        return shopSortMapper.selectShopSortList(shopSort);
    }

    /**
     * 新增商品分类
     * 
     * @param shopSort 商品分类
     * @return 结果
     */
    @Override
    public int insertShopSort(ShopSort shopSort)
    {
        return shopSortMapper.insertShopSort(shopSort);
    }

    /**
     * 修改商品分类
     * 
     * @param shopSort 商品分类
     * @return 结果
     */
    @Override
    public int updateShopSort(ShopSort shopSort)
    {
        return shopSortMapper.updateShopSort(shopSort);
    }

    /**
     * 批量删除商品分类
     * 
     * @param sortIds 需要删除的商品分类主键
     * @return 结果
     */
    @Override
    public int deleteShopSortBySortIds(Long[] sortIds)
    {
        return shopSortMapper.deleteShopSortBySortIds(sortIds);
    }

    /**
     * 删除商品分类信息
     * 
     * @param sortId 商品分类主键
     * @return 结果
     */
    @Override
    public int deleteShopSortBySortId(Long sortId)
    {
        return shopSortMapper.deleteShopSortBySortId(sortId);
    }
}
